package com.tjut.oop.hol6;

public class English extends Student {
	// 新增属性：演讲成绩
	private double lecture;

	// 父类方法的重写
	@Override
	public void showAll() {
		// 用super.调用父类方法
		super.showAll();
		setStuGrade(lecture * 0.5 + getFinalTerm() * 0.25 + getMidTerm() * 0.25);
		System.out.println("学生总成绩为：" + getStuGrade());
	}

	public English( double lecture,int stuAge, String stuNam, int stuNum, String stuGen, double midTerm, double finalTerm) {
		super(stuAge,stuNam, stuNum, stuGen, midTerm, finalTerm);
		this.lecture = lecture;
	}

}
